<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
  xmlns:ui="http://java.sun.com/jsf/facelets"
  xmlns:h="http://java.sun.com/jsf/html"
  xmlns:f="http://java.sun.com/jsf/core"
  xmlns:c="http://java.sun.com/jstl/core"
  template="/WEB-INF/layouts/templateAdmin.xhtml">

  <ui:define name="menu">
    <!-- INCLUDE MENU -->
  </ui:define>

  <ui:define name="content">
    <!-- INCLUDE CONTENT -->
    <h1 class="pageTitle">Create a new account</h1>

    <h:form id="addProduct">
      <h:panelGrid columns="2">
        <h:outputText class="inlineText" value="Name* : " />
        <h:panelGroup>
          <h:inputText value="#{flowScope.productAdd.name}" id="name"
            required="true" size="60" />
          <h:message for="name" />
        </h:panelGroup>

        <h:outputText value="ASIN :" />
        <h:panelGroup>
          <h:inputText value="#{flowScope.productAdd.ASIN}" id="asin"
            required="true" />
          <h:message for="asin" />
        </h:panelGroup>

        <h:outputText class="inlineText" value="Section :" />
        <h:panelGroup>
          <h:selectOneMenu value="#{flowScope.productAdd.categoryId}"
            id="categoryId">
            <f:selectItem itemValue="-1" itemLabel="--" />
            <c:forEach items="${flowScope.motherSections}" var="e">
              <f:selectItem itemValue="#{e.id}" itemLabel="#{e.name}" />
            </c:forEach>
          </h:selectOneMenu>
          <h:message for="categoryId" />
        </h:panelGroup>
      </h:panelGrid>

      <br />

      <h:commandButton value="Create Product" action="add" type="submit" />

    </h:form>
    <h:form>
      <h:commandLink action="back">
        Back
      </h:commandLink>
    </h:form>
  </ui:define>
</ui:composition>
